package com.rui.member.service.impl;

import com.rui.member.entity.Member;
import com.rui.member.mapper.MemberMapper;
import com.rui.member.service.MemberService;
import com.rui.member.vo.MemberQuery;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class MemberServiceImpl implements MemberService {

    @Resource
    private MemberMapper memberMapper;



    @Override
    public List<Member> getMemberList(MemberQuery param) {
       return memberMapper.getMemberList(param);
    }

    @Override
    public Long countMemberList(MemberQuery param) {
        return memberMapper.countMemberList(param);
    }

    @Override
    public void addMember(Member member) {
            memberMapper.addMember(member);
    }

    @Override
    public void deleteByMemberAccount(String memberAccount) {
        memberMapper.deleteByMemberAccount(memberAccount);
    }

    @Override
    public Member getMemberByaccount(Integer account) {
        return memberMapper.getMemberByaccount(account);
    }

    @Override
    public void updateMember(Member member) {
        memberMapper.updateMember(member);
    }

}
